package org.huangxq.bigscreen.service

import org.huangxq.bigscreen.data.SimpleIndConfigData
import org.huangxq.bigscreen.data.SimpleIndConfigId
import org.huangxq.bigscreen.repository.SimpleIndConfigRepository
import org.springframework.stereotype.Service

@Service
class SimpleIndConfigService(val simpleIndConfigRepository: SimpleIndConfigRepository) {

    fun getIndConfig(reportId: String, indId: String) = simpleIndConfigRepository.findById(SimpleIndConfigId(reportId, indId)).get()

    fun saveIndConfig(simpleIndConfigData: SimpleIndConfigData) = simpleIndConfigRepository.save(simpleIndConfigData)

}